package cn.itsource.api.openfeign;

import cn.itsource.constants.Constants;
import cn.itsource.fallback.LoginFallback;
import cn.itsource.pojo.dto.LoginRo;
import cn.itsource.result.JSONResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import javax.validation.Valid;

@FeignClient(value = Constants.Remote.SERVICE_UAA,fallbackFactory = LoginFallback.class)
public interface ILoginApiToService {
    @PostMapping(Constants.Remote.PREFIX_LOGIN_REMOTE)
    JSONResult saveLogin(@RequestBody @Valid LoginRo loginRo);
}
